package routers

import (
	beego "github.com/beego/beego/v2/server/web"
	"store-management/controllers"
)

func init() {
	beego.Router("/", &controllers.MainController{})

	beego.Router("/user/register", &controllers.UserController{}, "post:Register")
	beego.Router("/user/login", &controllers.UserController{}, "post:Login")

	beego.Router("/store/add", &controllers.StoreController{}, "post:Add")
	beego.Router("/store/list", &controllers.StoreController{}, "get:List")
	beego.Router("/store/update", &controllers.StoreController{}, "post:Update")
}
